package com.vlin.service.sche;

import org.quartz.Job;
import org.quartz.JobExecutionContext;
import org.quartz.JobExecutionException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Component;

@Component
public class AutoScheService extends AbstractScheService {

	private static final Logger logger = LoggerFactory.getLogger(AutoScheService.class);
	
	
	@Override
	public String getServiceId() {
		
		return "Automation";
	}

	@Override
	public boolean support(String serviceId) {
		if(serviceId == null) {
			return false;
		}
			
		return getServiceId().contentEquals(serviceId);
	}

	@Override
	public Class<? extends Job> job() {
		
		return SceneJob.class;
	}
	
	
	public static class SceneJob implements Job {

		@Override
		public void execute(JobExecutionContext context) throws JobExecutionException {
			logger.info("-----------hahahah-------");
		}
	}

}
